package com.ddwl.order.dao.mapper;

import com.ddwl.common.dao.mapper.TkMapper;
import com.ddwl.order.dao.model.OrderInfo;
import com.ddwl.order.dao.model.OrderSpu;
import com.ddwl.schema.bo.order.QueryOrderListBo;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * 订单商品表(OrderSpu)数据库交互Mapper
 *
 * @author makejava
 * @since 2020-06-02 14:48:17
 */
@Repository
public interface OrderSpuMapper extends TkMapper<OrderSpu> {
    /**
     * 根据订单号查询商品下单数量
     * @param OrderNo
     * @return
     */
    OrderSpu findByOrderNo(String OrderNo);

    List<OrderSpu> getOrderSpu(OrderInfo spu);

    List<OrderSpu> getSpuOrderList(@Param("query") QueryOrderListBo query);
}
